package com.gao.valueanno;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

import javax.annotation.PreDestroy;

/**
 * @author GaoXi
 * @date 2022/2/24 21:10
 */
@Component
//@PropertySource("classpath:application.properties")
public class TestDemoValue {


    public TestDemoValue(@Value("${my.name}")String name) {
        System.out.println(name);
    }
}
